      SUBROUTINE SETUP
      RETURN
      END
C   HS24
      SUBROUTINE EF(X,FX)
      INCLUDE 'FUCO.INC'
      DOUBLE PRECISION FX,X(NX),XKON
      ICF=ICF+1
      XKON=1.D0/(27.D0*DSQRT(3.D0))
      FX=XKON*((X(1)-3.D0)**2-9.D0)*X(2)**3
      RETURN
      END
      SUBROUTINE EGRADF(X,GRADF)
      INCLUDE 'FUCO.INC'
      DOUBLE PRECISION X(NX),GRADF(NX),XKON
      ICGF=ICGF+1
      XKON=1.D0/(27.D0*DSQRT(3.D0))
      GRADF(1)=XKON*X(2)**3*2.D0*(X(1)-3.D0)
      GRADF(2)= 3.D0* XKON*((X(1)-3.D0)**2-9.D0)*X(2)**2
      RETURN
      END
      SUBROUTINE EH(I,X,HXI)
      INCLUDE 'FUCO.INC'
      INTEGER I
      DOUBLE PRECISION X(NX),HXI
      CRES(I)=CRES(I)+1
      RETURN
      END
      SUBROUTINE EGRADH(I,X,GRADHI)
      INCLUDE 'FUCO.INC'
      INTEGER I
      DOUBLE PRECISION X(NX),GRADHI(NX)
      CGRES(I)=CGRES(I)+1
      RETURN
      END
      SUBROUTINE EG(I,X,GXI)
      INCLUDE 'FUCO.INC'
      INTEGER I
      DOUBLE PRECISION X(NX),GXI,W3
      IF ( GUNIT(1,I+NH) .EQ. -1 )CRES(I+NH)=CRES(I+NH)+1      
      W3=DSQRT(3.D0)
      GOTO(100,100,300,400,500),I
  100 CONTINUE
      GXI=X(I)
      RETURN
  300 CONTINUE
      GXI= X(1)/W3 -X(2)
      RETURN
  400 CONTINUE
      GXI= X(1)+W3*X(2)
      RETURN
  500 CONTINUE
      GXI=-X(1)-W3*X(2)+6.D0
      RETURN
      END
      SUBROUTINE EGRADG(I,X,GRADGI)
      INCLUDE 'FUCO.INC'
      INTEGER I,J
      DOUBLE PRECISION X(NX) ,GRADGI(NX),W3
      IF ( GUNIT(1,I+NH) .EQ. 1 )RETURN
      CGRES(I+NH)=CGRES(I+NH)+1
      DO      50      J=1,2
      GRADGI(J)=0.D0
   50 CONTINUE
      W3=DSQRT(3.D0)
      GOTO(100,100,300,400,500),I
  100 CONTINUE
      GRADGI(I)=1.D0
      RETURN
  300 CONTINUE
      GRADGI(1)= 1.D0/W3
      GRADGI(2)=-1.D0
      RETURN
  400 CONTINUE
      GRADGI(1)= 1.D0
      GRADGI(2)= W3
      RETURN
  500 CONTINUE
      GRADGI(1)=-1.D0
      GRADGI(2)=-W3
      RETURN
      END
      BLOCK DATA
      INCLUDE 'BLOCO.INC'
      INTEGER I,J
      DATA NAME/'HS24'/
      DATA X(1),X(2)/  1.D0, .50D0/
      DATA N/2/ , NH/0/ , NG/ 5/
      DATA DEL0/1.00D0/ ,TAU0/1.D0/ ,TAU/.1D0/
      DATA ((GUNIT(I,J),I=1,3),J=0,5)
     F    /-1,0,0,1,1,1,1,2,1,-1,0,0,-1,0,0,-1,0,0/
      END
